/* eslint-disable no-param-reassign */
import _ from 'lodash'
const initData = {
  name: undefined,
  code: undefined,
  brandId: undefined,
  company: (process.env.VUE_APP_Project || 'byd').toUpperCase(),
  saleArea: undefined,
  makeYear:undefined,
  trimLevel: [],
  trimLevelEditable: true
}
const newModel = {
  state: {
    newModelData: _.cloneDeep(initData),
    rightDrawerEvent: ''
  },
  mutations: {
    RESET_NEWMODEL_DATA () {

    },
    SET_NEWMODEL_DATA (state, val) {
      state.newModelData = Object.assign(_.cloneDeep(initData), val)
    },
    SET_ModelRightDrawerEvent (state, val) {
      state.rightDrawerEvent = val
    }
  },
  actions: {

  }
}
export default newModel
